package com.xnyzc.lhy.order.service.impl.system;

import com.baomidou.mybatisplus.core.conditions.Wrapper;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.xnyzc.lhy.common.entity.Qw;
import com.xnyzc.lhy.order.entity.system.OaSysGlobalConfig;
import com.xnyzc.lhy.order.mapper.system.OaSysGlobalConfigMapper;
import com.xnyzc.lhy.order.service.system.IOaSysGlobalConfigService;
import org.springframework.stereotype.Service;

/**
 * <p>
 * 系统全局配置表 服务实现类
 * </p>
 *
 * @author lhy@xnyzc.com
 * @since 2019-07-23
 */
@Service
public class OaSysGlobalConfigServiceImpl extends ServiceImpl<OaSysGlobalConfigMapper, OaSysGlobalConfig> implements IOaSysGlobalConfigService {

    /**
     *  更加tag获取配置信息
     * @param tag
     * @return
     */
    @Override
    public OaSysGlobalConfig getTagOne(String tag) {
        QueryWrapper<OaSysGlobalConfig> queryWrapper = new QueryWrapper<>();
        queryWrapper.eq(OaSysGlobalConfig.TAG,tag);
        OaSysGlobalConfig oaSysGlobalConfig =getOne(queryWrapper,true);
        return oaSysGlobalConfig;
    }
}
